import request from '@/config/axios'

// 手机消息 VO
export interface PhoneMsgVO {
  id: number // ID
}

// 手机消息 API
export const PhoneMsgApi = {
  // 查询手机消息分页
  getPhoneMsgPage: async (params: any) => {
    return await request.get({ url: `/wo/phone-msg/page`, params })
  },

  // 查询手机消息详情
  getPhoneMsg: async (id: number) => {
    return await request.get({ url: `/wo/phone-msg/get?id=` + id })
  },

  // 新增手机消息
  createPhoneMsg: async (data: PhoneMsgVO) => {
    return await request.post({ url: `/wo/phone-msg/create`, data })
  },

  // 修改手机消息
  updatePhoneMsg: async (data: PhoneMsgVO) => {
    return await request.put({ url: `/wo/phone-msg/update`, data })
  },

  // 删除手机消息
  deletePhoneMsg: async (id: number) => {
    return await request.delete({ url: `/wo/phone-msg/delete?id=` + id })
  },

  // 导出手机消息 Excel
  exportPhoneMsg: async (params) => {
    return await request.download({ url: `/wo/phone-msg/export-excel`, params })
  }
}